/*
 * Copyright © 2017 Cask Data, Inc.
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
 * use this file except in compliance with the License. You may obtain a copy of
 * the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations under
 * the License.
 */

@import "../../../styles/variables.scss";

.overview-container {
  flex: 0;
  position: relative;
  right: 0;
  // FIXME: For later use.
  // transition: 1s ease-in flex, 1s ease-in opacity, 1s ease-in right;
  width: 0;
  opacity: 0;

  &.show-overview {
    flex: 0 0 $overview-width;
    display: block;
    right: 0;
    opacity: 1;
    margin-top: 10px;

    @media (min-width: 700px) and (max-width: 900px) {
      position: absolute;
      right: 630px;
    }

    .overview-wrapper {
      position: fixed;
      width: $overview-width;
      height: calc(100vh - 225px);
      border-top: 1px solid rgba(219, 219, 219, 1);
      background: rgba(238, 238, 238, 1);
      box-shadow: 0px 1px 10px 0 rgba(0, 0, 0, 0.3);
      overflow-y: auto;
      display: flex;
      align-items: center;
      justify-content: center;
      > div {
        height: 100%;
        width: 100%;
        display: grid;
        // Top panel, metadata section and tab content
        grid-template-rows: auto auto 1fr;
        grid-template-columns: 100%;
      }

      > div.overview-error-container {
        display: flex;
        flex-direction: column;
        justify-content: center;
        margin-left: auto;
        margin-right: auto;
        max-width: 50vw;
        width: auto;
        padding: 0 20px;
        .btn-link {
          color: var(--brand-primary-color);
          cursor: pointer;
        }
        hr {
          width: 100%;
          color: #999999;
          background-color: #999999;
        }
        .message-container {
          font-weight: 500;
          ul,
          li {
            list-style: none;
            padding: 0;
          }
          .btn-link {
            color: var(--brand-primary-color);
          }
        }
      }
      > .fa.fa-spinner.fa-spin {
        color: gray;
        height: auto;
        width: auto;
      }
    }
  }
}
